package com.sihan.swvp.action.sjfx;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.sihan.swvp.action.BaseAction;
import com.sihan.swvp.service.sjfx.LeadDrivingService;

@Controller
@RequestMapping("sjfx/LeadDrivingAction")
public class LeadDrivingAction extends BaseAction{
	@Autowired
	private LeadDrivingService leadDrivingService;


	//<!-- 根据年份查询-同步视频-每月的条数 -->
	@ResponseBody
	@RequestMapping("/getMVideoCount") 
	public List<Map<String, Object>> getM_video_count(String year){
		List<Map<String, Object>> list = leadDrivingService.getM_video_count(year);
		return list;
	}

	//<!-- 根据年份查询同步视频-本周条数 -->
	@ResponseBody
	@RequestMapping("/getSynVideo_week") 
	public List<Map<String, Object>> getSynVideo_week(){
		List<Map<String, Object>> list = leadDrivingService.getM_video_count("week");
		return list;
	}
	//<!-- 根据年份查询同步视频-本月条数 -->
	@ResponseBody
	@RequestMapping("/getSynVideo_month") 
	public List<Map<String, Object>> getSynVideo_month(){
		List<Map<String, Object>> list = leadDrivingService.getM_video_count("month");
		return list;
	}
	/*******************************************************************/
	//<!-- 根据年份查询 违规视频每月数量和违规率 -->
	@ResponseBody
	@RequestMapping("/getwdCount") 
	public List<Map<String, Object>> getwdCount(String year){
		return leadDrivingService.getwdCount(year);
	}

	//<!-- 根据年份查询 违规视频 -本周- 数量和违规率 -->
	@ResponseBody
	@RequestMapping("/getwdCount_week") 
	public List<Map<String, Object>> getwdCount_week(){
		return leadDrivingService.getwdCount("week");
	}

	@ResponseBody
	@RequestMapping("/getwdCount_month") 
	public List<Map<String, Object>> getwdCount_month(){
		return leadDrivingService.getwdCount("month");
	}
/***************************************************************************/
	//<!-- 根据年份查询每月视频关联数量 -->
	@ResponseBody
	@RequestMapping("/getVideoMacth") 
	public List<Map<String, Object>> getVideoMacth(String year){
		return leadDrivingService.getVideoMacth(year);
	}

	//<!-- 根据年份查询本周视频关联数量 -->
	@ResponseBody
	@RequestMapping("/getVideoMacth_week") 
	public List<Map<String, Object>> getVideoMacth_week(){
		List<Map<String, Object>> list = leadDrivingService.getVideoMacth("week");
		return list;
	}

	//<!-- 根据年份查询本月视频关联数量 -->
	@ResponseBody
	@RequestMapping("/getVideoMacth_month") 
	public List<Map<String, Object>> getVideoMacth_month(){
		List<Map<String, Object>> list = leadDrivingService.getVideoMacth("month");
		return list;
	}

	/************近三日******************/
	@ResponseBody
	@RequestMapping("/getSynVideoCount_Today") 
	public List<Map<String, Object>> getSynVideo_Today(){
		List<Map<String, Object>> list = leadDrivingService.getM_video_count("today");
		return list;
	}

	@ResponseBody
	@RequestMapping("/getgetwd_Today") 
	public List<Map<String, Object>> getgetwd_Today(){
		List<Map<String, Object>> list = leadDrivingService.getwdCount("today");
		return list;
	}

	@ResponseBody
	@RequestMapping("/getVideoMacth_Today") 
	public List<Map<String, Object>> getVideoMacth_Today(){
		return leadDrivingService.getVideoMacth("today");
	}

	/******************************/

	@ResponseBody
	@RequestMapping("/getSynVideo_halfYear") 
	public List<Map<String, Object>> getSynVideo_halfYear(){
		List<Map<String, Object>> list = leadDrivingService.getM_video_count("halfYear");
		return list;
	}

	@ResponseBody
	@RequestMapping("/getgetwd_halfYear") 
	public List<Map<String, Object>> getgetwd_halfYear(){
		List<Map<String, Object>> list = leadDrivingService.getwdCount("halfYear");
		return list;
	}

	@ResponseBody
	@RequestMapping("/getVideoMacth_halfYear") 
	public List<Map<String, Object>> getVideoMacth_halfYear(){
		return leadDrivingService.getVideoMacth("halfYear");
	}


	//<!-- 巡视任务chart -->
	@ResponseBody
	@RequestMapping("/getXschart") 
	public List<Map<String, Object>> getXschart(){
		return leadDrivingService.getXschart();
	}

	//<!-- 工作任务任务chart -->
	@ResponseBody
	@RequestMapping("/getWorkchart") 
	public List<Map<String, Object>> getWorkchart(){
		return leadDrivingService.getWorkchart();
	}


	//今日任务总数（巡视任务、工作任务）
	@ResponseBody
	@RequestMapping("/taskSum_today") 
	public List<Map<String, Object>> taskSum_today(){
		List<Map<String, Object>> list = leadDrivingService.taskSum_today();
		return list;
	}

	//今日视频总数［关联视频、同步视频]
	@ResponseBody
	@RequestMapping("/videoSum_today") 
	public List<Map<String, Object>> videoSum_today(){
		List<Map<String, Object>> list = leadDrivingService.videoSum_today();
		return list;
	}

	//今日任务完成率（巡视完成率、工作完成率）
	@ResponseBody
	@RequestMapping("/taskLv_today") 
	public List<Map<String, Object>> taskLv_today(){
		List<Map<String, Object>> list = leadDrivingService.taskLv_today();

		return list;
	}
	
	//<!-- 本周每日视频同步数量 -->
	@ResponseBody
	@RequestMapping("/videoSyn_week")
	public List<Map<String, Object>> videoSyn_week(){
		List<Map<String, Object>> list = leadDrivingService.videoSyn_week();
		
		return list;
	}
	
	//<!-- 本周每日视频违规数量及违规率 -->
	@ResponseBody
	@RequestMapping("/videoWd_week")
	public List<Map<String, Object>> videoWd_week(){
		List<Map<String, Object>> list = leadDrivingService.videoWd_week();
		return list;
	}
	
	//<!-- 本周每日视频关联数量 -->
	@ResponseBody
	@RequestMapping("/videoManager_week")
	public List<Map<String, Object>> videoManager_week(){
		List<Map<String, Object>> list = leadDrivingService.videoManager_week();
		return list;
	}
	
	//<!-- 本月每日视频同步数量  -->
	@ResponseBody
	@RequestMapping("/videoSyn_month")
	public List<Map<String, Object>> videoSyn_month(){
		List<Map<String, Object>> list = leadDrivingService.videoSyn_month();
		return list;
	}
	
	//<!-- 本月每日视频违规数量及违规率 -->
	@ResponseBody
	@RequestMapping("/videoWd_month")
	public List<Map<String, Object>> videoWd_month(){
		List<Map<String, Object>> list = leadDrivingService.videoWd_month();
		return list;
	}
	
	//<!-- 本月每日视频关联数量 -->
	@ResponseBody
	@RequestMapping("/videoManager_month")
	public List<Map<String, Object>> videoManager_month(){
		List<Map<String, Object>> list = leadDrivingService.videoManager_month();
		return list;
	}

}
